import Cookies from 'js-cookie'

const TokenKey = 'Authorization'
const LoginKey = 'loginName'

export function getToken() {
  return Cookies.get(TokenKey)
}

export function setToken(token) {
  return Cookies.set(TokenKey, token)
}

export function removeToken() {
  return Cookies.remove(TokenKey)
}

export function getLoginName() {
  return Cookies.get(LoginKey)
}

export function setLoginName(loginName) {
  return Cookies.set(LoginKey, loginName)
}

export function removeLoginName() {
  return Cookies.remove(LoginKey)
}